package com.android.commcount.dialog;

import android.view.View;
import android.widget.SeekBar;

import androidx.fragment.app.FragmentManager;

import com.android.baselibrary.dialog.BaseDialogFragment;
import com.android.commcount.R;
import com.android.commcount.R2;
import com.android.commcount.bean.Count_DetailInfo;
import com.android.commcount.event.Event_Count_ChangeCircleRadius;
import com.android.commcount.manager.ImageRecConfig;
import com.android.commcount.ui.view.CommCount_AdjustView;

import org.greenrobot.eventbus.EventBus;

import java.util.Map;

import butterknife.OnClick;

/**
 * Created by Administrator on 2018/8/29.
 */

public class Count_EditSize_DialogFragment extends BaseDialogFragment {

    CommCount_AdjustView commcount_adjustview;

    Count_DetailInfo countDetailInfo;

    @Override
    protected int getLayoutId() {
        return R.layout.dialog_editsize;
    }

    @Override
    protected void initData() {
        if (countDetailInfo != null) {
            commcount_adjustview.setCountDetailInfo(countDetailInfo);
        }
    }

    @Override
    protected void initView() {
        commcount_adjustview = mRootView.findViewById(R.id.commcount_adjustview);
    }

    @Override
    protected int getShowDirection() {
        return BaseDialogFragment.Direction_FromBottom;
    }

    @Override
    public void setData(Map<String, Object> params) {
        if (params != null) {
            countDetailInfo = (Count_DetailInfo) params.get("countDetailInfo");
        }
    }

    public static BaseDialogFragment showDialog(FragmentManager fragmentManager, Map<String, Object> params) {
        Count_EditSize_DialogFragment dialogFragment = new Count_EditSize_DialogFragment();
        dialogFragment.setData(params);
        dialogFragment.show(fragmentManager, "");
        return dialogFragment;
    }

//    @OnClick({ R2.id.iv_close})
//    public void onViewClicked(View view) {
//        int id = view.getId();
//        if (id == R.id.iv_close) {
//            dismissWithAnim();
//        }
//    }
}
